<!DOCTYPE html>
<html>

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Sugar</title>
</head>

<body>
  <script>

    const arr = [{ isSelect: false }, { isSelect: false }, { isSelect: true }];

    // filter() 过滤功能
    const res = arr.filter(item => item.isSelect);

    // 化简前的写法
    // const res = arr.filter(item => {
    //   return item.isSelect;
    // });

    console.log(res);

  </script>
</body>

</html>